<head>
<script>
if (window.testRunner)
    testRunner.dumpAsText();

function test() {
  var e = document.createEvent("StorageEvent");
  var target = document.getElementById("target");
  e.initEvent("beforecut", new Boolean(false), new Boolean(true));
  target.dispatchEvent(e);
  document.createElement("div");
}
</script>
</head>
<menu onbeforecut=test()>
<div id="target"></div><style onload=test()></style>
</menu>
<div>Pass when no crash observed.</div>
